package com.liu.tools.qiuniu;

import com.liu.tools.conf.ConfigurerEx;

/**
 * @DateTime 2015年8月28日 下午2:44:01
 * @Company 华视传媒
 * @Author 刘兴密
 * @QQ 63972012
 * @Desc 七牛配置信息
 */
public class QiniuConfig {

	public QiniuConfig(){
		this.accessKey = ConfigurerEx.getProperty("qiniu.access.key");
		this.secretKey = ConfigurerEx.getProperty("qiniu.secret.key");
		this.bucketName = ConfigurerEx.getProperty("qiniu.bucket.name");
		this.uploadUrl = ConfigurerEx.getProperty("qiniu.upload.url");
		this.domain = ConfigurerEx.getProperty("qiniu.bucket.domain");
		this.picViewParam = ConfigurerEx.getProperty("qiniu.pic.view.param");
		this.bucketType = ConfigurerEx.getPropertyInt("qiniu.bucket.type");
		this.rsUrl = ConfigurerEx.getProperty("qiniu.rs.url");
	}
	
	public QiniuConfig(String accessKey, String secretKey, String bucketName,
			String uploadUrl, String domain, String picViewParam, int bucketType) {

		this.accessKey = accessKey;
		this.secretKey = secretKey;
		this.bucketName = bucketName;
		this.uploadUrl = uploadUrl;
		this.domain = domain;
		this.picViewParam = picViewParam;
		this.bucketType = bucketType;
	}

	/**
	 * Access Key
	 */
	private String accessKey;
	
	/**
	 * Secret Key
	 */
	private String secretKey;
	
	/**
	 * Bucket Name
	 */
	private String bucketName;
	
	/**
	 * 上传url
	 */
	private String uploadUrl;
	
	/**
	 * 七牛空间主域名
	 */
	private String domain;
	
	/**
	 * 缩略图参数配置
	 */
	private String picViewParam;
	
	/**
	 * 空间类型
	 */
	private int bucketType;
	
	private String rsUrl;

	public String getAccessKey() {
		return accessKey;
	}

	public void setAccessKey(String accessKey) {
		this.accessKey = accessKey;
	}

	public String getSecretKey() {
		return secretKey;
	}

	public void setSecretKey(String secretKey) {
		this.secretKey = secretKey;
	}

	public String getBucketName() {
		return bucketName;
	}

	public void setBucketName(String bucketName) {
		this.bucketName = bucketName;
	}

	public String getUploadUrl() {
		return uploadUrl;
	}

	public void setUploadUrl(String uploadUrl) {
		this.uploadUrl = uploadUrl;
	}

	public String getDomain() {
		return domain;
	}

	public void setDomain(String domain) {
		this.domain = domain;
	}

	public String getPicViewParam() {
		return picViewParam;
	}

	public void setPicViewParam(String picViewParam) {
		this.picViewParam = picViewParam;
	}

	public int getBucketType() {
		return bucketType;
	}

	public void setBucketType(int bucketType) {
		this.bucketType = bucketType;
	}

	public String getRsUrl() {
		return rsUrl;
	}

	public void setRsUrl(String rsUrl) {
		this.rsUrl = rsUrl;
	}
	
}
